/*
 * SPDX-FileCopyrightText: 2016-2021 Espressif Systems (Shanghai) CO LTD
 *
 * SPDX-License-Identifier: CC0-1.0
 */

#pragma once

#include <stdbool.h>
#include <stdint.h>
#include "esp_err.h"

#define T_RADIO_VOLUME_MAX              ((uint8_t)30u)
#define T_RADIO_VOLUME_MIN              ((uint8_t)0u)

#ifdef __cplusplus
extern "C" {
#endif

/**
 * @brief Creates t-radio.
 * 
 * @return ESP_OK -or- error code.
*/
esp_err_t t_radio_create(QueueHandle_t event_queue);

/**
 * @brief Gets current volume level;
 * 
 * @param[in,out] volume_level Pointer to volume level.
 * 
 * @return ESP_OK -or- error code.
*/
esp_err_t t_radio_get_volume_level(uint8_t* volume_level);

/**
 * @brief Sets current volume level.
 * 
 * @param[in] volume_level Volume level.
 * 
 * @return ESP_OK -or- error code.
*/
esp_err_t t_radio_set_volume_level(const uint8_t volume_level);

#ifdef __cplusplus
}
#endif